package com.boot.dao;

import com.boot.entity.*;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 *供应商管理Dao
 */
@Mapper
public interface SupplierManagementDao {

    public List<Map<String,Object>> queryAllSupplier(@Param("companyId") int companyId,@Param("supplierName")String supplierName);
    public Map<String,Object> querySupplierDetails(int supplierId);
    public List<Map<String,Object>> queryCompanyCheck(@Param("supplierId") int supplierId, @Param("companyId") int companyId);
    public List<Map<String,Object>> querySupplierCheck(@Param("supplierId") int supplierId, @Param("companyId") int companyId);
    public List<Map<String,Object>> queryCompanyApply(@Param("companyId") int companyId,@Param("auditStatus")String auditStatus,@Param("supplierName")String supplierName);
    public Map<String,Object> queryCompanyApplyById(int csId);
    public List<Map<String,Object>> queryPowerApply(@Param("companyId") int companyId,@Param("auditStatus")String auditStatus,@Param("supplierName")String supplierName);
    public Map<String,Object> queryPowerApplyById(int bePSupplierId);
    public List<Map<String,Object>> queryBlackApply(@Param("companyId") int companyId,@Param("auditStatus")String auditStatus,@Param("supplierName")String supplierName);
    public Map<String,Object> queryBlackApplyById(int blacklistId);
    public Map<String,Object> queryBlackApplyCheck(int blacklistId);
    public List<Map<String,Object>> queryYearScore(@Param("years") int years,@Param("companyId") int companyId,@Param("supplierName")String supplierName);
    public List<Map<String,Object>> queryMonthScore(@Param("supplierId") int supplierId,@Param("years") int years);
    public boolean updataBeCSupplier(BeCSupplier beCSupplier);
    public boolean saveCompanyApplyCheck(CSCheck csCheck);
    public boolean saveCompanySupplier(CompanySupplier companySupplier);
    public List<Integer> queryAllPowerId(int companyId);
    public boolean savePowerSupplier (PowerPlantSupplier pSupplier);
    public boolean updataBePSupplier(BePSupplier bePSupplier);
    public boolean savePSCheck(PSCheck psCheck);
    public CompanySupplier queryCompanySupplier(@Param("companyId") int companyId,@Param("supplierId") int supplierId);
    public boolean updataCompanySupplier(CompanySupplier companySupplier);
    public List<Integer> queryPowerSupplierId(@Param("companyId") int companyId,@Param("supplierId") int supplierId);
    public boolean updataBlackList(BlackList blackList);
    public boolean saveBlackListCheck(BlackListCheck blackListCheck);
    public boolean updataPowerSupplierBlack(@Param("companyId") int companyId,@Param("supplierId") int supplierId);
    public boolean updataPowerSupplierType(@Param("companyId") int companyId,@Param("supplierId") int supplierId,@Param("supplierType") String supplierType);
}
